package sft.BancodeDados;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;

public class CriaConexao{    
    
    public Connection getConnection() throws SQLException{
        try {
            Class.forName("com.mysql.jdbc.Driver");
            System.out.println("Conectado ao banco!");
        } catch (ClassNotFoundException ex) {
            Logger.getLogger(CriaConexao.class.getName()).log(Level.SEVERE, null, ex);
        }
        return DriverManager.getConnection("jdbc:mysql:" + new LerEntrada().Config() + "/sft","root","root");
    }
}
